package com.jzit168.library_base.baseVB

import android.os.Bundle
import androidx.viewbinding.ViewBinding
import com.jzit168.library_base.base.BaseActivity

/**
 *@Desc: 携带创建ViewBinding的基类Activity
 *@Author: Android Developer
 *@Date: 2020/10/14
 *
 **/
abstract class BaseVBActivity<VB : ViewBinding> : BaseActivity() {

    open lateinit var binding: VB

    abstract fun getViewBinding(): VB

    override fun initView(savedInstanceState: Bundle?) {
        super.initView(savedInstanceState)
        binding = getViewBinding()
        setContentView(binding.root)
    }
}